package org.agile2soft.nexoma.tapestry.pages;

import org.apache.tapestry5.EventConstants;
import org.apache.tapestry5.annotations.InjectPage;
import org.apache.tapestry5.annotations.OnEvent;
import org.apache.tapestry5.ioc.annotations.Inject;
import org.slf4j.Logger;

public class Forbidden
{
	@Inject
	private Logger logger;

	@InjectPage
	private Portal portalPage;
	
	@OnEvent(value=EventConstants.ACTIVATE)
	Object doGoHome() {
		logger.info(".activate.doGoHome -> forbidden !");
		portalPage.setMessageCode("forbidden");
		return portalPage;
	}

}